using System;


namespace KeanuMvc.Reference {

    /// <summary>
    /// Summary description for NVelocityEngineFactory.
    /// </summary>
    public class TemplateEngineFactory {
        /// <summary>
        /// Creates a new instance of NVelocityFileEngine class.
        /// </summary>
        /// <param name="templateDirectory">The template directory.</param>
        /// <param name="cacheTemplate">if set to <c>true</c> [cache template].</param>
        /// <returns></returns>
        public static ITemplateEngine CreateTemplateFileEngine(string templateDirectory, bool cacheTemplate) {
            return new TemplateFileEngine(templateDirectory, cacheTemplate);
        }

        /// <summary>
        /// Creates a new instance of NVelocityAssemblyEngine class.
        /// </summary>
        /// <param name="assemblyName">Name of the assembly.</param>
        /// <param name="cacheTemplate">if set to <c>true</c> [cache template].</param>
        /// <returns></returns>
        public static ITemplateEngine CreateTemplateAssemblyEngine(string assemblyName, bool cacheTemplate) {
            return new TemplateAssemblyEngine(assemblyName, cacheTemplate);
        }

        /// <summary>
        /// Creates a new instance of NVelocityMemoryEngine class.
        /// </summary>
        /// <param name="cacheTemplate">if set to <c>true</c> [cache template].</param>
        /// <returns></returns>
        public static ITemplateEngine CreateTemplateMemoryEngine(bool cacheTemplate) {
            return new TemplateMemoryEngine(cacheTemplate);
        }
    }
}
